import { Catch } from '@midwayjs/decorator';
import { Context } from 'egg';

@Catch()
export class AllErrorFilter {
  async catch(err: Error, ctx: Context) {
    console.log(err)
    return {code: 1000, msg: err.message}
  }
}